import request from './request'


export const handelDjOrder = (config) => {

  // 操作预付款订单
  return request({
    // params: {
    //   action: 'cancel_djorder'
    // },
    data: config
  })
}

export const handelOrder = config => {
  // 订单操作
  // 确认收货
  return request({
    params: {
      action: 'confirmend',
    },
    data: config
  })
}


export const applyRefund = (config) => {
  // 申请退款
  return request({
    params: {
      action: 'refund'
    },
    data: config
  })
}

export const getOrderList = (config) => {
  // 获取采购订单
  return request({
    params: {
      action: 'purchase_order'
    },
    data: config
  })
}

export const getPurchaseOrderList = (config) => {
  // 获取采购需求订单
  return request({
    params: {
      action: 'purchase'
    },
    data: config
  })
}


export const refundDetail = (orderno) => {
  // 获取退款流程进度详情
  return request({
    data: {
      action: 'refund_detail',
      orderno: orderno
    }
  })
}

export const entryGroup = (config) => {
  // 确认成团
  return request({
    params: {
      action: 'group_confirm'
    },
    data: config
  })
}


